home *** CD-ROM | disk | FTP | other *** search
/ Skunkware 5 / Skunkware 5.iso / tls / tls074c.sunsparc.Z / tls074c.sunsparc / lib / vtcl / tests / align.tcl < prev    next >
Encoding:
Text File  |  1995-07-20  |  852 b   |  43 lines

  1. # CVS $Id: align.tcl,v 1.1 1995/02/03 17:14:58 zibi Exp $
  2. ##
  3. ### Example usage of "VxAlignedForm"
  4. ##
  5.  
  6.  
  7. proc closeCB { cbs } {
  8.     VtClose
  9.     exit
  10. }
  11.  
  12.  
  13.  
  14. #
  15. #
  16. # Start Program
  17. #
  18. #
  19. set app [VtOpen "VxAlignedForm"]
  20.  
  21. set dlog [VtFormDialog $app.Dialog\
  22.         -title "My Aligned form"\
  23.         -ok -okCallback closeCB]
  24.  
  25. set form [VxAlignedForm $dlog.Align\
  26.         { {"Name:"         {VtText -columns 15 -value "John Doe"}}
  27.           {"Address:"      {VtText -value "123 Hickory Street"}}
  28.           {"Phone Number:" {VtText -value "800-555-1212"}}
  29.           {"Status:"       {VtRadioBox -numColumns 3 -borderWidth 1}}}]
  30.  
  31. VtSetValues $form -leftSide FORM -rightSide FORM
  32.  
  33. set statusbox [VxGetVar $form "widget4"]
  34. VtToggleButton $statusbox.friend -label "Friend"   -value 1
  35. VtToggleButton $statusbox.enemy  -label "Enemy"  
  36. VtToggleButton $statusbox.turkey -label "Turkey"    
  37.  
  38.  
  39. VtShow $dlog
  40.  
  41. VtMainLoop
  42.  
  43.